﻿using System;
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace IOT4Week1Day1.Domain.Models
{
    /// <summary>
    /// 数据字典的键值
    /// </summary>
    public class DictKey
    {
        [Key]
        public int KId { get; set; }

        /// <summary>
        /// 字典名称
        /// </summary>
        [Required]
        [StringLength(30)]
        public string DictName { get; set; }

        /// <summary>
        /// 字典的代码
        /// </summary>
        [Required]
        [StringLength(10)]
        public string DictCode { get; set; }

        /// <summary>
        /// 字典的备注
        /// </summary>
        [StringLength(100)]
        public string Remark { get; set; }

        /// <summary>
        /// 创建时间
        /// </summary>
        public DateTime? CreatedTime { get; set; }


        //导航属性
        public virtual List<DictData> DictItems { get; set; } 
    }
}
